﻿using IntoMes.PLC;
using IntoMes.ViewModels;
using Prism.Ioc;

namespace IntoMes.Global
{
    public class Locator
    {
        private readonly IContainerProvider _provider;
        public static Locator Instance = null;
        public Locator(IContainerProvider provider)
        {
            _provider = provider;
        }


        //Model
        public Service Service => _provider.Resolve<Service>();
        //ViewModel
        public StationStatusViewModel StationStatus => _provider.Resolve<StationStatusViewModel>();
        public ProductionQueryViewModel ProdcutionQuery => _provider.Resolve<ProductionQueryViewModel>();
        public MainWindowViewModel MainWindowViwModel => _provider.Resolve<MainWindowViewModel>();
        public SparePartsManageViewModel SparePartsManage => _provider.Resolve<SparePartsManageViewModel>();

        public StopTimeViewModel StopTime => _provider.Resolve<StopTimeViewModel>();
    }
}
